home *** CD-ROM | disk | FTP | other *** search
Text File | 2001-03-11 | 1.6 KB | 68 lines | [TEXT/ToyS] |
- tell application "iView PhotoMover"
-
- (* get/set properties *)
-
- get the name
- get the version
- get the frontmost
-
- -- Save current settings
- set klog to get the Log
- set ksound to get the Sound
- set kdetails to get the Details
- set khost to get the Host
-
- -- Settable options (note they are not saved when the program exits).
-
- set the Log to false -- All error message go to screen
- set the Sound to false -- don't play sound at end of upload.
- set the Details to true -- Set Details to true for tracking down problems.
- set the Details to false
-
- (* function samples *)
-
- exists -- app is running
- data size of name -- ie "iView PhotoMover"
-
- -- Get a file to upload...
- set afile to choose file
- activate
-
- -- 0 = PhotoPoint
- -- 1 = ClubPhoto
- -- 2 = zing
- -- 3 = ImageStation
- -- 4 = NikonNet
- -- 5 = FotoTime
- set the Log to true -- save result to log file...
-
- repeat with hostid from 0 to 5
- set the Host to hostid
- try
-
- -- set timeout to some large number
- with timeout of 3600 seconds -- how long to upload? 1 hour?
-
- -- upload the image to the current site.
- open afile
- -- open t into album "test" with keyword "keyword" with description "test"
-
- -- Note: Currently no site have support for keywords and descriptions yet. this will be added
- -- as site vendors help us add this feature.
- end timeout
-
- on error msg
- display dialog msg & return & "Uploading to host index " & hostid
- end try
- end repeat
-
- -- restore the settings
- set the Log to klog
- set the Sound to ksound
- set the Details to kdetails
- set the Host to khost
-
- -- quit
-
- end tell
-